home *** CD-ROM | disk | FTP | other *** search
/ Shareware Grab Bag / Shareware Grab Bag.iso / 011 / chgpath.arc / CHGPATH.DOC < prev    next >
Encoding:
Text File  |  1987-04-06  |  4.1 KB  |  114 lines

  1.  
  2.  
  3.  
  4.  
  5.      CHGPATH  (Change Directory)                    Version 1.0 (4/87)
  6.      Command
  7.  
  8.  
  9.  
  10.      Copyright (C) 1987 by Scott Mason, except where noted in the 
  11.        source code,  All Rights Reserved.
  12.  
  13.      Permission is hereby granted for use by non-profit entities only.
  14.      Distribution of this file, CHGPATH.EXE, and/or CHGPATH.C in any form
  15.      for a fee is prohibited.
  16.  
  17.      This file must accompany CHGPATH.EXE to where ever it goes.
  18.     
  19.  
  20.  
  21.      Written by Scott Mason
  22.                 4050 Jay Em Circle
  23.                 Ellicott City, MD  21043
  24.  
  25.      ------------------------------------------------------------------
  26.  
  27.  
  28.      Purpose:  Allows you the make permanent changes to the PATH
  29.  
  30.  
  31.                environment string from the DOS command line without
  32.  
  33.  
  34.                having to retype the entire PATH command string.
  35.  
  36.  
  37.      
  38.  
  39.  
  40.      Format:   CHGPATH  +[drive][path]
  41.                CHGPATH  -[drive][path]
  42.  
  43.  
  44.            
  45.                Where:      + is to add the string that follows it to
  46.                              the end of the PATH environment string.  
  47.  
  48.                            - is to remove the string that follows it 
  49.                              from the PATH environment string.
  50.  
  51.                            [drive] is a valid DOS drive letter (i.e. C:)
  52.  
  53.                            [path] is a valid DOS directory path (i.e. \DOS)
  54.  
  55.  
  56.  
  57.      Remarks:     All additions to the PATH string are appended to the end
  58.                of the current PATH string.  If no PATH environment string is
  59.                found, one is created with the path the user specified as its
  60.                only path.  If no path environment string exists and an attempt
  61.                is made to remove a path, the message "No path is set ..." will
  62.                be displayed.
  63.  
  64.                   There is no validation of the drive or paths the user
  65.                includes on the command line.  And no length check is made
  66.                on the resulting PATH string.
  67.  
  68.                   The new PATH setting is displayed and can be redirected.
  69.                   
  70.  
  71.  
  72.                   Written using the DeSmet C88 C compiler package, v2.51
  73.                Acknowledgement and graditude is hereby given to:
  74.  
  75.                         John M Sellens, who wrote the getpath & parse_path
  76.                             functions, and
  77.                         Dan Lewis, who wrote the execute_string (and
  78.                             subsequent) functions.
  79.  
  80.      
  81.                   Any comments and/or suggestions are welcome.  I visit two
  82.                BBSs fairly often.  They are:
  83.  
  84.                   Tom Vervacke's Baltimore-Washington BBS 
  85.                   (301) 381-6441
  86.  
  87.                   Robert Blacher's Computer Connections BBS
  88.                   (202) 547-7621
  89.  
  90.  
  91.      Future Improvements:
  92.  
  93.                   Allowing the user to specify where in the PATH environement
  94.                string to add a new path.
  95.  
  96.  
  97.      Examples:
  98.      
  99.               C:\>CHGPATH    +D:\WP  >NUL
  100.  
  101.  
  102.  
  103.                  Will add the path D:\WP to the end of the current PATH
  104.                  environement string.  If the PATH environment string before
  105.                  the command was:
  106.  
  107.                  C:;C:\;C:\DOS;C:\UTILS
  108.                   
  109.                  then it will be
  110.                   
  111.                  C:;C:\;C:\DOS;C:\UTILS;D:\WP
  112.                  
  113.  
  114.  
  115.                  after the CHGPATH command is executed.
  116.  
  117.                  Because ">NUL" is also on the command line, the new
  118.                  PATH setting is not displayed.
  119.  
  120.  
  121.               C:\>CHGPATH    -d:\reflex
  122.  
  123.  
  124.  
  125.                  Will remove the path D:\REFLEX from the current PATH
  126.                  environement string.  If the PATH environment string before
  127.                  the command was:
  128.  
  129.                  C:;C:\;C:\DOS;C:\UTILS;D:\REFLEX;D:\WP
  130.                   
  131.                  then it will be
  132.                   
  133.                  C:;C:\;C:\DOS;C:\UTILS;D:\WP
  134.                  
  135.  
  136.  
  137.                  after the CHGPATH command is executed.  The new PATH
  138.                  setting will be displayed.
  139.  
  140.  
  141.  
  142.